package com.rem.concurrency.juc.my13Single;

/**
 * 饿汉模式
 *
 * @author Rem
 * @date 2021-03-10
 */

public class Hungry {

    private Hungry() {
    }

    /**
     * 虚拟机启动的时候就创建了对象
     */
    private final static Hungry HUNGRY = new Hungry();

    public static Hungry getHungry() {
        return HUNGRY;
    }

}
